<?php


namespace Hilaoyu\LaravelPrivateApi;


use Hilaoyu\LaravelExtend\Supports\SubApp;

class PrivateApiService
{
    static function regiserRoutes($path, $namespace = '', $route_config = [], $type = '')
    {
        data_set($route_config,'prefix',config('private_api_service.route_prefix','laravel-private-api'));
        $middleware = (array)data_get($route_config,'middleware',[]);
        $middleware[] = 'assents_route_exclude';
        data_set($route_config,'middleware',$middleware);
        SubApp::registerRoutes($path,$namespace,$route_config);
    }
}